Scroll to navigation

fi_nic(3) Libfabric v1.7.2 fi_nic(3)

NAME

fi_nic - Fabric network interface card attributes

NETWORK INTERFACE CARD ATTRIBUTES

The fid_nic structure defines attributes for a struct fi_info that is directly associated with underlying networking hardware and may be returned directly from calling fi_getinfo(3). The format of fid_nic and the related substructures are defined below.

Note that not all fields of all structures may be available. Unavailable or fields that are not applicable to the indicated device will be set to NULL or 0.

struct fid_nic {
    struct fid             fid;
    struct fi_device_attr *device_attr;
    struct fi_bus_attr    *bus_attr;
    struct fi_link_attr   *link_attr;
    void                  *prov_attr;
};
struct fi_device_attr {
    char *name;
    char *device_id;
    char *device_version;
    char *vendor_id;
    char *driver;
    char *firmware;
};
struct fi_pci_attr {
    uint16_t domain_id;
    uint8_t  bus_id;
    uint8_t  device_id;
    uint8_t  function_id;
};
struct fi_bus_attr {
    enum fi_bus_type       bus_type;
    union {
        struct fi_pci_attr pci;
    } attr;
};
struct fi_link_attr {
    char               *address;
    size_t             mtu;
    size_t             speed;
    enum fi_link_state state;
    char               *network_type;
};
    

Device Attributes

Device attributes are used to identify the specific virtual or hardware NIC associated with an fi_info structure.

The operating system name associated with the device. This may be a logical network interface name (e.g. eth0 or eno1) or an absolute filename.
This is a vendor specific identifier for the device or product.
Indicates the version of the device.
Indicates the name of the vendor that distributes the NIC.
The name of the driver associated with the device
The device's firmware version.

Bus Attributes

The bus attributes are used to identify the physical location of the NIC in the system.

Indicates the type of system bus where the NIC is located. Valid values are FI_BUS_PCI or FI_BUS_UNKNOWN.
The domain where the PCI bus is located. Valid only if bus_type is FI_BUS_PCI.
The PCI bus identifier where the device is located. Valid only if bus_type is FI_BUS_PCI.
The identifier on the PCI bus where the device is located. Valid only if bus_type is FI_BUS_PCI.
The function on the device being referenced. Valid only if bus_type is FI_BUS_PCI.

Link attributes describe low-level details about the network connection into the fabric.

The primary link-level address associated with the NIC, such as a MAC address. If multiple addresses are available, only one will be reported.
The maximum transfer unit of link level frames or packets, in bytes.
The active link data rate, given in bits per second.
The current physical port state. Possible values are FI_LINK_UNKNOWN, FI_LINK_DOWN, and FI_LINK_UP, to indicate if the port state is unknown or not applicable (unknown), inactive (down), or active (up).
Specifies the type of network interface currently active, such as Ethernet or InfiniBand.

Provider Attributes

Provider attributes reference provider specific details of the device. These attributes are both provider and device specific. The attributes can be interpretted by fi_tostr(3). Applications may also use the other attribute fields, such as related fi_fabric_attr: prov_name field, to determine an appropriate structure to cast the attributes. The format and definition of this field is outside the scope of the libfabric core framework, but may be available as part of a provider specific header file included with libfabric package.

NOTES

The fid_nic structure is returned as part of a call to fi_getinfo(3). It is automatically freed as part of calling fi_freeinfo(3)

SEE ALSO

fi_getinfo(3)

AUTHORS

OpenFabrics.

2018-10-05 Libfabric Programmer's Manual